package com.sangfor.ssl.service.setting;

import android.text.TextUtils;
import com.sangfor.bugreport.logger.Log;

/* loaded from: classes2.dex */
public class GlobalSettingUtils {
    private static final Object LOCK = new Object();
    private static final String TAG = "GlobalSettingUtils";

    public static void updateTwfid(String str) {
        Log.error(TAG, "Call updateTwfid! Twfid:" + str, new Throwable());
        synchronized (LOCK) {
            if (TextUtils.isEmpty(str)) {
                Log.warn(TAG, "updateTwfid failed! twfid is empty!");
            }
            SettingManager.getInstance().set(SettingManager.TWFID_TWFID, str);
        }
    }

    public static String getTwfid() {
        String str;
        Log.info(TAG, "Call getTwfid!");
        synchronized (LOCK) {
            str = (String) SettingManager.getInstance().get(SettingManager.TWFID_TWFID);
        }
        return str;
    }
}
